package com.qdaily.supportlibrary.util;

import in.srain.cube.util.CLog;

/**
 * Created by song on 15/5/11.
 */
public class QLog {

    public static boolean isDebug = false;

    public static void time(String tag)
    {
        i(tag, "current second time:"+System.currentTimeMillis());
    }

    public static void i(String tag, String msg) {
        CLog.v(tag, msg);
    }

    public static void i(String tag, String msg, Throwable throwable) {
        CLog.v(tag, msg, throwable);
    }

    public static void i(String tag, String msg, Object... args) {
        CLog.v(tag, msg, args);
    }


    public static void d(String message) {
        if (isDebug)
            Logger.d(message);
    }

    public static void d(String tag, String message) {
        if (isDebug)
            Logger.d(tag, message);
    }

    public static void d(String message, int methodCount) {
        if (isDebug)
            Logger.d(message, methodCount);
    }

    public static void d(String tag, String message, int methodCount) {
        if (isDebug)
            Logger.d(tag, message, methodCount);
    }

    public static void json(String message) {
        if (isDebug)
            Logger.json(message);
    }

    public static void w(String tag, String msg) {
        if (isDebug)
            CLog.w(tag, msg);
    }

    public static void w(String tag, String msg, Object... args) {
        if (isDebug)
            CLog.w(tag, msg, args);
    }

    public static void w(String tag, String msg, Throwable throwable) {
        if (isDebug)
            CLog.w(tag, msg, throwable);
    }


    public static void e(String tag, String msg) {
        CLog.e(tag, msg);
    }

    public static void e(String tag, String msg, Object... args) {
        CLog.e(tag, msg, args);
    }

    public static void e(String tag, String msg, Throwable throwable) {
        CLog.e(tag, msg, throwable);
    }
}
